package com.clark.crawler.novel.factory;

import com.clark.crawler.novel.deal.ChapterDeal;

/**
 * description:
 *
 * @author tianhua.xie（tianhua.xie@ucarinc.com）
 * @date 2018-12-27 09:43:33
 * @version 1.0
 */
public abstract class IChapterDealFactory {
    private static ChapterDeal novelDeal;
    /**
     * description:
     *
     * @author tianhua.xie（tianhua.xie@ucarinc.com）
     * @date 2018-12-27 09:43:37
     * @param
     * @return com.clark.crawler.novel.deal.NovelDeal
     **/
    protected abstract ChapterDeal create();

    public ChapterDeal getInstance(){
        if (novelDeal == null){
            novelDeal = create();
        }
        return novelDeal;
    }
}
